module List :
  sig
    val length : 'a list -> int
    val hd : 'a list -> 'a
    val tl : 'a list -> 'a list
    val nth : 'a list -> int -> 'a
    val rev : 'a list -> 'a list
    val append : 'a list -> 'a list -> 'a list
    val rev_append : 'a list -> 'a list -> 'a list
    val concat : 'a list list -> 'a list
    val flatten : 'a list list -> 'a list
    val iter : ('a -> unit) -> 'a list -> unit
    val iteri : (int -> 'a -> unit) -> 'a list -> unit
    val map : ('a -> 'b) -> 'a list -> 'b list
    val rev_map : ('a -> 'b) -> 'a list -> 'b list
    val fold_left : ('a -> 'b -> 'a) -> 'a -> 'b list -> 'a
    val fold_right : ('a -> 'b -> 'b) -> 'a list -> 'b -> 'b
    val iter2 : ('a -> 'b -> unit) -> 'a list -> 'b list -> unit
    val map2 : ('a -> 'b -> 'c) -> 'a list -> 'b list -> 'c list
    val rev_map2 : ('a -> 'b -> 'c) -> 'a list -> 'b list -> 'c list
    val fold_right2 :
      ('a -> 'b -> 'c -> 'c) -> 'a list -> 'b list -> 'c -> 'c
    val for_all : ('a -> bool) -> 'a list -> bool
    val exists : ('a -> bool) -> 'a list -> bool
    val for_all2 : ('a -> 'b -> bool) -> 'a list -> 'b list -> bool
    val exists2 : ('a -> 'b -> bool) -> 'a list -> 'b list -> bool
    val mem : 'a -> 'a list -> bool
    val memq : 'a -> 'a list -> bool
    val find : ('a -> bool) -> 'a list -> 'a
    val filter : ('a -> bool) -> 'a list -> 'a list
    val find_all : ('a -> bool) -> 'a list -> 'a list
    val partition : ('a -> bool) -> 'a list -> 'a list * 'a list
    val assoc : 'a -> ('a * 'b) list -> 'b
    val assq : 'a -> ('a * 'b) list -> 'b
    val mem_assoc : 'a -> ('a * 'b) list -> bool
    val mem_assq : 'a -> ('a * 'b) list -> bool
    val remove_assoc : 'a -> ('a * 'b) list -> ('a * 'b) list
    val remove_assq : 'a -> ('a * 'b) list -> ('a * 'b) list
    val split : ('a * 'b) list -> 'a list * 'b list
    val combine : 'a list -> 'b list -> ('a * 'b) list
    val sort : ('a -> 'a -> int) -> 'a list -> 'a list
    val stable_sort : ('a -> 'a -> int) -> 'a list -> 'a list
    val fast_sort : ('a -> 'a -> int) -> 'a list -> 'a list
    val merge : ('a -> 'a -> int) -> 'a list -> 'a list -> 'a list
    val wrap : 'a -> 'a list
    val cons : 'a -> 'a list -> 'a list
    val rec_remove_fast : 'a -> 'a list -> 'a list -> 'a list
    val remove_fast : 'a -> 'a list -> 'a list
    val sum : int list -> int
    val sumf : float list -> float
    val sum_map : ('a -> int) -> 'a list -> int
    val sumf_map : ('a -> float) -> 'a list -> float
    val rec_count : ('a -> bool) -> int -> 'a list -> int
    val count : ('a -> bool) -> 'a list -> int
    val rev_iter : ('a -> unit) -> 'a list -> unit
    val iter3 :
      ('a -> 'b -> 'c -> 'd) -> 'a list -> 'b list -> 'c list -> unit
    val rec_mapi : (int -> 'a -> 'b) -> int -> 'a list -> 'b list
    val mapi : (int -> 'a -> 'b) -> 'a list -> 'b list
    val map3 :
      ('a -> 'b -> 'c -> 'd) -> 'a list -> 'b list -> 'c list -> 'd list
    val split3 : ('a * 'b * 'c) list -> 'a list * 'b list * 'c list
    val fold_left2 : ('a -> 'b -> 'b) -> 'a list -> 'b -> 'b
    val transpose : 'a list list -> 'a list list
  end
module Array :
  sig
    external length : 'a array -> int = "%array_length"
    external get : 'a array -> int -> 'a = "%array_safe_get"
    external set : 'a array -> int -> 'a -> unit = "%array_safe_set"
    external make : int -> 'a -> 'a array = "caml_make_vect"
    external create : int -> 'a -> 'a array = "caml_make_vect"
    val init : int -> (int -> 'a) -> 'a array
    val make_matrix : int -> int -> 'a -> 'a array array
    val create_matrix : int -> int -> 'a -> 'a array array
    val append : 'a array -> 'a array -> 'a array
    val concat : 'a array list -> 'a array
    val sub : 'a array -> int -> int -> 'a array
    val copy : 'a array -> 'a array
    val fill : 'a array -> int -> int -> 'a -> unit
    val blit : 'a array -> int -> 'a array -> int -> int -> unit
    val to_list : 'a array -> 'a list
    val of_list : 'a list -> 'a array
    val iter : ('a -> unit) -> 'a array -> unit
    val map : ('a -> 'b) -> 'a array -> 'b array
    val iteri : (int -> 'a -> unit) -> 'a array -> unit
    val mapi : (int -> 'a -> 'b) -> 'a array -> 'b array
    val fold_left : ('a -> 'b -> 'a) -> 'a -> 'b array -> 'a
    val fold_right : ('b -> 'a -> 'a) -> 'b array -> 'a -> 'a
    val sort : ('a -> 'a -> int) -> 'a array -> unit
    val stable_sort : ('a -> 'a -> int) -> 'a array -> unit
    val fast_sort : ('a -> 'a -> int) -> 'a array -> unit
    external unsafe_get : 'a array -> int -> 'a = "%array_unsafe_get"
    external unsafe_set : 'a array -> int -> 'a -> unit = "%array_unsafe_set"
    val sum : int array -> int
    val sumf : float array -> float
    val sum_map : ('a -> int) -> 'a array -> int
    val sumf_map : ('a -> float) -> 'a array -> float
    val find : ('a -> bool) -> 'a array -> 'a
    val fold : ('a -> 'b -> 'b) -> 'a array -> 'b -> 'b
    val map2 : ('a -> 'b -> 'c) -> 'a array -> 'b array -> 'c array
    val iter2 : ('a -> 'b -> 'c) -> 'a array -> 'b array -> unit
    val rev_iter : ('a -> 'b) -> 'a array -> unit
    exception Found
    val exists : ('a -> bool) -> 'a array -> bool
    val for_all : ('a -> bool) -> 'a array -> bool
    val count : ('a -> bool) -> 'a array -> int
    val argmin : 'a array -> int
    val argmax : 'a array -> int
    val min : 'a array -> 'a
    val max : 'a array -> 'a
    val rev_inplace : 'a array -> unit
    val transpose : 'a array array -> 'a array array
    val flattenl_helper : 'a array -> int -> 'a array list -> 'a array
    val copy_list : 'a array -> int -> 'a list -> int
    val flattenl : 'a list array -> 'a array
    val filter : ('a -> bool) -> 'a array -> 'a array
    val partition : ('a -> bool) -> 'a array -> 'a array * 'a array
    val pos_maxf : float array -> int
    val pos_minf : float array -> int
    val rev : 'a array -> 'a array
  end
module Hashtbl :
  sig
    type ('a, 'b) t = ('a, 'b) Hashtbl.t
    val create : ?random:bool -> int -> ('a, 'b) t
    val clear : ('a, 'b) t -> unit
    val reset : ('a, 'b) t -> unit
    val copy : ('a, 'b) t -> ('a, 'b) t
    val add : ('a, 'b) t -> 'a -> 'b -> unit
    val find : ('a, 'b) t -> 'a -> 'b
    val find_all : ('a, 'b) t -> 'a -> 'b list
    val mem : ('a, 'b) t -> 'a -> bool
    val remove : ('a, 'b) t -> 'a -> unit
    val replace : ('a, 'b) t -> 'a -> 'b -> unit
    val iter : ('a -> 'b -> unit) -> ('a, 'b) t -> unit
    val fold : ('a -> 'b -> 'c -> 'c) -> ('a, 'b) t -> 'c -> 'c
    val length : ('a, 'b) t -> int
    val randomize : unit -> unit
    type statistics =
      Hashtbl.statistics = {
      num_bindings : int;
      num_buckets : int;
      max_bucket_length : int;
      bucket_histogram : int array;
    }
    val stats : ('a, 'b) t -> statistics
    module type HashedType =
      sig type t val equal : t -> t -> bool val hash : t -> int end
    module type S =
      sig
        type key
        type 'a t
        val create : int -> 'a t
        val clear : 'a t -> unit
        val reset : 'a t -> unit
        val copy : 'a t -> 'a t
        val add : 'a t -> key -> 'a -> unit
        val remove : 'a t -> key -> unit
        val find : 'a t -> key -> 'a
        val find_all : 'a t -> key -> 'a list
        val replace : 'a t -> key -> 'a -> unit
        val mem : 'a t -> key -> bool
        val iter : (key -> 'a -> unit) -> 'a t -> unit
        val fold : (key -> 'a -> 'b -> 'b) -> 'a t -> 'b -> 'b
        val length : 'a t -> int
        val stats : 'a t -> statistics
      end
    module Make :
      functor (H : HashedType) ->
        sig
          type key = H.t
          type 'a t = 'a Hashtbl.Make(H).t
          val create : int -> 'a t
          val clear : 'a t -> unit
          val reset : 'a t -> unit
          val copy : 'a t -> 'a t
          val add : 'a t -> key -> 'a -> unit
          val remove : 'a t -> key -> unit
          val find : 'a t -> key -> 'a
          val find_all : 'a t -> key -> 'a list
          val replace : 'a t -> key -> 'a -> unit
          val mem : 'a t -> key -> bool
          val iter : (key -> 'a -> unit) -> 'a t -> unit
          val fold : (key -> 'a -> 'b -> 'b) -> 'a t -> 'b -> 'b
          val length : 'a t -> int
          val stats : 'a t -> statistics
        end
    module type SeededHashedType =
      sig type t val equal : t -> t -> bool val hash : int -> t -> int end
    module type SeededS =
      sig
        type key
        type 'a t
        val create : ?random:bool -> int -> 'a t
        val clear : 'a t -> unit
        val reset : 'a t -> unit
        val copy : 'a t -> 'a t
        val add : 'a t -> key -> 'a -> unit
        val remove : 'a t -> key -> unit
        val find : 'a t -> key -> 'a
        val find_all : 'a t -> key -> 'a list
        val replace : 'a t -> key -> 'a -> unit
        val mem : 'a t -> key -> bool
        val iter : (key -> 'a -> unit) -> 'a t -> unit
        val fold : (key -> 'a -> 'b -> 'b) -> 'a t -> 'b -> 'b
        val length : 'a t -> int
        val stats : 'a t -> statistics
      end
    module MakeSeeded :
      functor (H : SeededHashedType) ->
        sig
          type key = H.t
          type 'a t = 'a Hashtbl.MakeSeeded(H).t
          val create : ?random:bool -> int -> 'a t
          val clear : 'a t -> unit
          val reset : 'a t -> unit
          val copy : 'a t -> 'a t
          val add : 'a t -> key -> 'a -> unit
          val remove : 'a t -> key -> unit
          val find : 'a t -> key -> 'a
          val find_all : 'a t -> key -> 'a list
          val replace : 'a t -> key -> 'a -> unit
          val mem : 'a t -> key -> bool
          val iter : (key -> 'a -> unit) -> 'a t -> unit
          val fold : (key -> 'a -> 'b -> 'b) -> 'a t -> 'b -> 'b
          val length : 'a t -> int
          val stats : 'a t -> statistics
        end
    val hash : 'a -> int
    val seeded_hash : int -> 'a -> int
    val hash_param : int -> int -> 'a -> int
    val seeded_hash_param : int -> int -> int -> 'a -> int
    val keys_to_list : ('a, 'b) Hashtbl.t -> 'a list
    val dfind : ('a, 'b) Hashtbl.t -> 'a -> 'b -> 'b
  end
module Hashset :
  sig
    type 'a t = ('a, unit) Hashtbl.t
    val create : ?random:bool -> int -> ('a, 'b) Hashtbl.t
    val add : ('a, unit) Hashtbl.t -> 'a -> unit
    val mem : ('a, 'b) Hashtbl.t -> 'a -> bool
    val iter : ('a -> unit) -> ('a, unit) Hashtbl.t -> unit
    val fold : ('a -> 'b -> 'b) -> ('a, unit) Hashtbl.t -> 'b -> 'b
    val to_list : ('a, unit) Hashtbl.t -> 'a list
    val sum_map : ('a -> int) -> ('a, unit) Hashtbl.t -> int
    val sumf_map : ('a -> float) -> ('a, unit) Hashtbl.t -> float
    val filter : ('a -> bool) -> ('a, unit) Hashtbl.t -> unit
    type 'a t' = ('a, unit) Hashtbl.t
    module type S =
      sig
        type key
        type t
        val create : int -> t
        val clear : t -> unit
        val copy : t -> t
        val add : t -> key -> unit
        val remove : t -> key -> unit
        val mem : t -> key -> bool
        val iter : (key -> unit) -> t -> unit
        val fold : (key -> 'b -> 'b) -> t -> 'b -> 'b
        val length : t -> int
        val to_list : t -> key list
        val filter : (key -> bool) -> t -> unit
      end
  end
module String :
  sig
    external length : string -> int = "%string_length"
    external get : string -> int -> char = "%string_safe_get"
    external set : string -> int -> char -> unit = "%string_safe_set"
    external create : int -> string = "caml_create_string"
    val make : int -> char -> string
    val copy : string -> string
    val sub : string -> int -> int -> string
    val fill : string -> int -> int -> char -> unit
    val blit : string -> int -> string -> int -> int -> unit
    val concat : string -> string list -> string
    val iter : (char -> unit) -> string -> unit
    val iteri : (int -> char -> unit) -> string -> unit
    val map : (char -> char) -> string -> string
    val trim : string -> string
    val escaped : string -> string
    val index : string -> char -> int
    val rindex : string -> char -> int
    val index_from : string -> int -> char -> int
    val rindex_from : string -> int -> char -> int
    val contains : string -> char -> bool
    val contains_from : string -> int -> char -> bool
    val rcontains_from : string -> int -> char -> bool
    val uppercase : string -> string
    val lowercase : string -> string
    val capitalize : string -> string
    val uncapitalize : string -> string
    type t = string
    val compare : t -> t -> int
    external unsafe_get : string -> int -> char = "%string_unsafe_get"
    external unsafe_set : string -> int -> char -> unit
      = "%string_unsafe_set"
    external unsafe_blit : string -> int -> string -> int -> int -> unit
      = "caml_blit_string" "noalloc"
    external unsafe_fill : string -> int -> int -> char -> unit
      = "caml_fill_string" "noalloc"
    val match_beg : string -> string -> int -> bool
    val match_end : string -> string -> int -> bool
    val suffix : string -> string -> bool
    val prefix : string -> string -> bool
  end
module Heap :
  sig
    type 'a heap =
      'a Heap.heap = {
      mutable data : 'a array;
      mutable size : int;
      lessthan : 'a -> 'a -> bool;
    }
    val create : ('a -> 'a -> bool) -> int -> 'a heap
    val realloc : 'a heap -> int -> unit
    val size : 'a heap -> int
    val is_empty : 'a heap -> bool
    val grow : 'a heap -> unit
    val swap : 'a heap -> int -> int -> unit
    val sift_down : 'a heap -> int -> unit
    val sift_up : 'a heap -> int -> unit
    val add : 'a heap -> 'a -> unit
    val remove_min : 'a heap -> unit
    val get : 'a heap -> int -> 'a
    val remove : 'a heap -> int -> unit
    val min : 'a heap -> 'a
    val rebuild : 'a heap -> unit
    val build : ('a -> 'a -> bool) -> 'a array -> 'a heap
    val remove_all : 'a heap -> ('a -> bool) -> unit
    val clear : 'a heap -> unit
    val iter : ('a -> 'b) -> 'a heap -> unit
    val to_array : 'a heap -> 'a array
    val to_list : 'a heap -> 'a list
  end
module Timer :
  sig
    val start_time_hash : (string, float) Hashtbl.t
    val elapsed_time_hash : (string, float) Hashtbl.t
    val _get_elapsed : string -> float
    val _get_start : string -> float
    val start : string -> unit
    val delta : string -> float
    val elapsed : string -> float
    val stop : string -> unit
    val clear : string -> unit
  end
val compose : ('a -> 'b) -> ('c -> 'a) -> 'c -> 'b
val ( $ ) : ('a -> 'b) -> ('c -> 'a) -> 'c -> 'b
val identity : 'a -> 'a
val f_true : 'a -> bool
val rev_range : int -> int list
val range : int -> int list
val log_zero : float
val log_one : float
exception EmptyList
val dotprod : float list -> float list -> float
val adotprod : float array -> float array -> float
val maxf : float -> float -> float
val minf : float -> float -> float
val fast_exp : float -> float
val logsumexp : float list -> float
val logsumexp2 : float -> float -> float
val alogsumexp : float array -> float
val sumexp : float list -> float
val asumexp : float array -> float
val logdiffexp2 : float -> float -> float
val output_int : out_channel -> int -> unit
val output_float : out_channel -> float -> unit
val output_sep : out_channel -> string -> string array -> unit
val __verbose : bool ref
val __debugging : bool ref
val __logfile : string ref
val common_arguments : (string * Arg.spec * string) list
val log_hash : (string, out_channel) Hashtbl.t
val register_log : string -> out_channel -> unit
val unregister_log : string -> unit
val log_exists : string -> bool
val log_stream : string -> out_channel
val log_string : string -> string -> unit
val logf : string -> ('a, unit, string, unit) format4 -> 'a
val log_normal : string
val log_verbose : string
val log_debug : string
val nlogf : ('a, unit, string, unit) format4 -> 'a
val vlogf : ('a, unit, string, unit) format4 -> 'a
val dlogf : ('a, unit, string, unit) format4 -> 'a
val log_args : unit -> unit
val common_log_init : unit -> unit
val debug : string -> unit
val string_of_ilist : int list -> string
val string_of_flist : float list -> string
val string_of_iarray : int array -> string
val string_of_farray : float array -> string
val normalize_inplace_raw : float array -> unit
val normalize_inplace_log : float array -> unit
val normalize_raw : float array -> float array
val normalize_log : float array -> float array
val stats_make : unit -> float ref * float ref * float ref
val stats_wadd : float ref * float ref * float ref -> float -> float -> unit
val stats_add : float ref * float ref * float ref -> float -> unit
val stats_n : 'a * 'b * 'c ref -> 'c
val stats_sum : 'a ref * 'b * 'c -> 'a
val stats_mean : float ref * 'a * float ref -> float
val stats_var : float ref * float ref * float ref -> float
val stats_epsilon : float
val stats_stddev : float ref * float ref * float ref -> float
val stats_stderr : float ref * float ref * float ref -> float
type libra_filetype =
    ACFile
  | BNFile
  | MNFile
  | DataFile
  | SPNFile
  | UnknownFile
val filetype : string -> libra_filetype
